package com.example.aircraft;


import com.example.aircraft.base.AbstractFlyingObject;




import java.util.ArrayList;
import java.util.List;

/**
 * @author lzf
 *
 */
public class EnemyObject{
    private List<AbstractFlyingObject> Observers = new ArrayList<>();
    public void addObserver(AbstractFlyingObject Observer){
            Observers.add(Observer);
    }
    public void notifyAllObserver(){
        for(AbstractFlyingObject obs:Observers){
            obs.update();
        }
    }
}
